using System;
using System.Collections.Generic; 
using System.Linq;  
using System.Text;  
using System.Data.Linq.Mapping;
using System.Data.Linq;
namespace MRSite.Entity  
{
    /// <summary>
    /// 充值
    /// </summary>
     [Table(Name = "recharge")]
    public class Recharge : Entity
	{ 
		/// <summary>
		///
		/// </summary>
		[Column(Name = "id", IsPrimaryKey = true, CanBeNull = false, IsVersion = true)]
		public override int id{ get; set; }

         
             /// <summary>
		/// 订单号
		/// </summary>
        [Column(Name = "order_no")]
        public String order_no { get; set; } 

        /// <summary>
        ///
        /// </summary>
        [Column(Name = "user_id")]
        public int user_id { get; set; }

		/// <summary>
		/// 银行名称
		/// </summary>
		[Column(Name = "bankname")]
		public String bankname{ get; set; } 

		/// <summary>
		/// 银行卡号
		/// </summary>
		[Column(Name = "bankaccount")]
		public String bankaccount{ get; set; } 

		/// <summary>
		/// 户名
		/// </summary>
		[Column(Name = "account")]
		public String account{ get; set; } 

		/// <summary>
		/// 支行
		/// </summary>
		[Column(Name = "zhihang")]
		public String zhihang{ get; set; } 

		/// <summary>
		///充值金额
		/// </summary>
		[Column(Name = "amount")]
		public Decimal amount{ get; set; } 

		/// <summary>
		///
		/// </summary>
		[Column(Name = "addtime",IsDbGenerated=true)]
		public DateTime addtime{ get; set; } 

		/// <summary>
		/// 审核时间/打款时间
		/// </summary>
		[Column(Name = "checktime")]
		public DateTime? checktime{ get; set; } 

		/// <summary>
		///0待处理,1已处理,已作废
		/// </summary>
		[Column(Name = "status")]
		public int status{ get; set; } 

		/// <summary>
		///
		/// </summary>
		[Column(Name = "remark")]
		public String remark{ get; set; } 

		/// <summary>
		///货币种类:XJB现金币,CFXFB重复消费币,GWB购物币
		/// </summary>
		[Column(Name = "feetype")]
		public String feetype{ get; set; }

        /// <summary>
        ///充值类别(1:线上充值;2：线下充值)
        /// </summary>
        [Column(Name = "rechagetypeid")]
        public int rechagetypeid { get; set; }

        /// <summary>
        ///充值方式(system:系统；wx:微信；alipay:支付宝：bank：银行转帐)
        /// </summary>
        [Column(Name = "rechargetype")]
        public string rechargetype { get; set; }

        /// <summary>
        ///充值外部交易号
        /// </summary>
        [Column(Name = "out_trade_no")]
        public string out_trade_no { get; set; }

        /// <summary>
        ///凭证
        /// </summary>
        [Column(Name = "imgpath")]
        public string imgpath { get; set; }

        /// <summary>
        ///管理员备注
        /// </summary>
        [Column(Name = "adminremark")]
        public string adminremark { get; set; }

           /// <summary>
        /// 用途 Service：服务网点充值；
        /// </summary>
        [Column(Name = "source")]
        public string source { get; set; }
         


        private EntityRef<Customer> _member;

        /// <summary>
        /// 
        /// </summary>
        [Association(Storage = "_member", ThisKey = "user_id", OtherKey = "id")]
        public Customer CustomerItem
        {
            get { return this._member.Entity; }
            set { this._member.Entity = value; }
        }
	 } 
}    

